<template>
  <div>
    <h1>App</h1>
    <p>count:{{ count }}</p>
     <p>count:{{ num }}</p>
    <button @click="increment">累加count</button>
    <button @click="incrementN({ n: 10 })">累加N count</button>
    <button @click="decrement">累减count</button>
    <button @click="incrementWait">等一等累加count</button>

  </div>
</template>

<script>
import { mapMutations, mapState } from "vuex";
/* import store from "./stores";
console.log(store); */
export default {
  name: "App",
  mounted(){
    console.log(this,"app");
  },
  computed:{
    ...mapState(["count","num"])
  },
  methods: {
    ...mapMutations(["increment","decrement","incrementN","incrementWait"])
  },
 
  
}
</script>

<style></style>